﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Shop.Core.Domain.Customers;
using Shop.Core.Properties;

namespace Shop.Core.Domain.Orders
{
    public class PaymentReceiptedNode : BaseFlowNode
    {
        public override OrderStatus StatusCode
        {
            get
            {
                return OrderStatus.PaymentReceipted;
            }
        }

        public override bool CanPay(Order order)
        {
            return (order.CapturedAmount.Value - order.RefundedAmount.Value - order.GrandTotal.Value) > 0;
        }

        public override bool CanEdit(Order order)
        {
            return true;
        }

        public override bool CanCancel(Order order)
        {
            return true;
        }
    }
}
